//
//  HomePageTableViewCell.m
//  拉勾7.17
//
//  Created by dllo on 16/7/20.
//  Copyright © 2016年 YMJ. All rights reserved.
//

#import "HomePageTableViewCell.h"

@implementation HomePageTableViewCell
- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier {
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        [self createView];
    }
    return self;
}
- (void)createView {
    self.companyIcon = [[UIImageView alloc] initWithFrame:CGRectMake(16, 16, 90, 90)];
    self.companyIcon.backgroundColor = [UIColor redColor];
    [self.contentView addSubview:_companyIcon];
    self.jobName = [[UILabel alloc] initWithFrame:CGRectMake(122, 15, 176, 21)];
    self.jobName.backgroundColor = [UIColor orangeColor];
    [self.contentView addSubview:_jobName];
    self.salary = [[UILabel alloc] initWithFrame:CGRectMake(328, 15, 78, 21)];
    self.salary.backgroundColor = [UIColor blueColor];
    [self.contentView addSubview:_salary];
    self.companyName = [[UILabel alloc] initWithFrame:CGRectMake(122, 44, 176, 21)];
    self.companyName.backgroundColor = [UIColor brownColor];
    [self.contentView addSubview:_companyName];
    self.address = [[UILabel alloc] initWithFrame:CGRectMake(122, 84, 176, 21)];
    self.address.backgroundColor = [UIColor yellowColor];
    [self.contentView addSubview:_address];
    self.type = [[UILabel alloc] initWithFrame:CGRectMake(328, 84, 78, 21)];
    self.type.backgroundColor = [UIColor grayColor];
    [self.contentView addSubview:_type];
    self.date = [[UILabel alloc] initWithFrame:CGRectMake(122, 113, 284, 21)];
    self.date.backgroundColor = [UIColor cyanColor];
    [self.contentView addSubview:_date];

}


- (void)awakeFromNib {
    // Initialization code
}
// 修改被选中的样式
- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];
    UIView *vLine =  [[UIView alloc] initWithFrame:CGRectMake(0, 0, 2, 30)];
    vLine.backgroundColor = [UIColor colorWithRed:0.306 green:0.314 blue:0.337 alpha:1.000];
    self.selectedBackgroundView = vLine;



    // Configure the view for the selected state
}

@end
